package cn.com.sbell.vss.csg.vsclient.ipcamera;

import java.io.IOException;
import java.util.ArrayList;
import java.util.Collections;
import java.util.Enumeration;
import java.util.List;
import java.util.Properties;

public class GetIpCameraVersion {
	private static List modelTypeList;
	static {
		modelTypeList = Collections.synchronizedList(new ArrayList());
		Properties prop = new Properties();
		try {
			prop.load(GetIpCameraVersion.class
					.getResourceAsStream("CommanderForKX.properties"));
		} catch (IOException e) {
			
			e.printStackTrace();
		}
		Enumeration nameEnum = prop.propertyNames();
		while (nameEnum.hasMoreElements()) {
			String property = (String) nameEnum.nextElement();
			String value = null;

			value = prop.getProperty(property);
			modelTypeList.add(value);
			
		}
	}
	public static boolean getType(String productVersion){
		return modelTypeList.contains(productVersion);
	}
	public static void main(String[] args){
		System.out.println(GetIpCameraVersion.getType("KX-HCM8"));
	}
}
